/*
 * 气泡对话框容器
 * */

'use strict';
var React = require('react');
class ReLeftBubbleBox extends React.Component {
    constructor(props) {
        super(props);
        this.getMainClassname=this.getMainClassname.bind(this);
    }


    getMainClassname(){
        if(this.props.reClass!=undefined){
            return "ReLeftBubbleBox "+this.props.reClass;
        }
        else{
            return 'ReLeftBubbleBox';
        }
    }

    render(){
        var style;
        if(this.props.topPosition!=undefined){
            style={
                top:this.props.topPosition
            }
        }
        return  <div className={this.getMainClassname()}>
            <div className="Bot" style={this.props.topPosition!=undefined?style:{}}></div>
            <div className="Top"  style={this.props.topPosition!=undefined?style:{}}></div>
            <div className="Content">
                {this.props.children}
            </div>
        </div>
    }
}

module.exports = ReLeftBubbleBox;